package com.cms.mapper;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.cms.entity.User;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Insert;
import java.util.List;


@Mapper
public interface UserMapper extends BaseMapper<User> {

    IPage pageC(IPage<User> page);

    IPage pageCC(IPage<User> page, @Param(Constants.WRAPPER) Wrapper wrapper);

//    @Insert("insert into `user`(avatarUrl,no,name,password,age,sex,phone,roleId,isvalid)"+
//            "values (#{avatarUrl},#{no},#{name},#{password},#{age},#{sex},#{phone},#{roleId},#{isvalid})")
//            int insert(User user);



}

/*
@Mapper
public interface UserMapper extends BaseMapper<User> {

    // 修改方法签名，添加参数用于传递请求参数
    IPage<User> pageCC(IPage<User> page, @Param("phone") String phone, @Param("no") String no);
}
*/